package com.njxxted.activiti.modules.api.entity;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import org.springframework.lang.NonNull;

import java.io.Serializable;
import java.time.LocalDateTime;
import java.util.Map;

/**
 * 描述：推送vo
 * <p>
 * 作者：Ostrich Hu
 * 时间：2019/11/20 15:55 星期三
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@ApiModel(value = "PushVo", description = "推送表")
public class PushVo implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "主键id")
    private String id;

    @ApiModelProperty(value = "业务id")
    private String businessId;

    @ApiModelProperty(value = "业务数据")
    private Map<String, Object> businessData;

    @ApiModelProperty(value = "推送的消息")
    private String pushMsg;

    @ApiModelProperty(value = "接收客户端id")
    @NonNull
    private String acceptClientId;

    @ApiModelProperty(value = "发起客户端id")
    private String startClientId;

    @ApiModelProperty(value = "推送目标路径")
    @NonNull
    private String destination;

    @ApiModelProperty(value = "推送时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss ", timezone = "GMT+8")
    private LocalDateTime pushDate;

    @ApiModelProperty(value = "模板对应参数")
    private String conditionMap;

    @ApiModelProperty(value = "类型")
    private String types;

    @ApiModelProperty(value = "状态（0未读，1已读，2忽略）")
    private Integer status;

    @ApiModelProperty(value = "备注")
    private String remark;

    @ApiModelProperty(value = "处理时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss ", timezone = "GMT+8")
    private LocalDateTime pushResult;

    public PushVo() {

    }
}
